package robotleMvc.ui.lizhi
{
	import _Pan3D.program.Program3DManager;
	import _Pan3D.program.shaders.BaseShader;
	
	import flash.display.Sprite;
	import flash.display3D.Context3D;
	import flash.display3D.Program3D;
	
	import test.vo.Lizhilizhi;
	
	public class LizhiView extends Sprite
	{
		private var _context3D:Context3D;
		private var lizhilizhi:Lizhilizhi;
		private var lizhilizhiprogram:Program3D;
		public function LizhiView(tempContext3D:Context3D)
		{
			_context3D=tempContext3D;
			addLizhi();
		}
		private function addLizhi():void
		{
			lizhilizhi = new Lizhilizhi(_context3D);
			lizhilizhi.y=20
			lizhilizhi.x=430;
			lizhilizhi.z=600;
			lizhilizhi.colorVec = new Vector.<Number>();
			lizhilizhi.colorVec.push(256/256,256/256,256/256,0);
			lizhilizhiprogram = Program3DManager.getInstance().getProgram(BaseShader.BASESHADER);
		}
		public function updata():void
		{
			_context3D.setProgram(lizhilizhiprogram);
			lizhilizhi.update();
		}
	}
}